package colleaction.sort;

import java.util.Comparator;

public class ItemComparetor implements Comparator<Item> {

	@Override
	public int compare(Item o1, Item o2) {
		if (o1.getItemId() != o2.getItemId()) {
			return o1.getItemId() - o2.getItemId();
		} else {
			return o1.getCount() - o2.getCount();
		}
	}

}
